package request

type CalendarAdd struct {
	Type string `form:"type" json:"type" binding:"required,oneof='holidays' 'works'" label:"类型"`
	Date string `form:"date" json:"date" binding:"required,len=8" label:"日期"`
}

func (CalendarAdd CalendarAdd) GetMessages() ValidatorMessages {
	return ValidatorMessages{
		"required": ":label为必填",
		"oneof":    ":label不正确",
		"len":      ":label格式不正确",
	}
}
